package com.zhang.repository;

import com.zhang.entity.Salt;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;

/**
 * 21级 计科院·张艺澄
 * 2024.12.8
 */
public interface SaltRepository extends JpaRepository<Salt, Integer>, JpaSpecificationExecutor<Salt> {
/*    @Query(value="select s from Salt s where s.salt= :salt")*/
    @Query(value = "select * from t_salt where salt=?1",nativeQuery = true)
    Salt findByUserName(String salt);
}
